
getSprite=()=>{
    var prefabIndex = 0;
    for (var i = 0; i < global.UnityNode.length; i++) {
      var d = global.UnityNode[i];
      if (d.SpritePath != "") {
        var nodeId = d.ID;
        var meta = readFileMeta(global.cocosPath + d.SpritePath);
        var uid;
        for(var j in meta.subMetas) {
          uid = meta.subMetas[j].uuid;
        }
        prefabIndex++;
        global.curID++;
        global.finialInfo.push(addSprite(nodeId, uid));
      }
    }
}
addSprite = (nodeId,uid)=>{
    var d = {
        "__type__": "cc.Sprite",
        "_name": "",
        "_objFlags": 0,
        "node": {
          "__id__": nodeId
        },
        "_enabled": true,
        "_materials": [
          {
            "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
          }
        ],
        "_srcBlendFactor": 770,
        "_dstBlendFactor": 771,
        "_spriteFrame": {
          "__uuid__": uid
        },
        "_type": 0,
        "_sizeMode": 0,
        "_fillType": 0,
        "_fillCenter": {
          "__type__": "cc.Vec2",
          "x": 0,
          "y": 0
        },
        "_fillStart": 0,
        "_fillRange": 0,
        "_isTrimmedMode": true,
        "_atlas": null,
        "_id": ""
    }
    if(global.isShowId) d["ID"] = global.curID;
    return d;
}
module.exports = {
    getSprite,
};